/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package biz;

import dao.ResultDAO;
import entity.Result;
import java.sql.SQLException;
import java.util.ArrayList;

/**
 *
 * @author Young Ran
 */
public class ResultBO {
    
    //DISPLAY RESULT:
    public ArrayList<Result> getAllResult() throws SQLException{
        return new ResultDAO().getAllResult();
    }
    public void addResult(Result item) throws SQLException
    {
        new ResultDAO().addResult(item);
    }
    
    public ArrayList<Result> getAllUnapprovedResult() throws SQLException{
        return new ResultDAO().getAllUnapprovedResult();
    }
    
    public void approveResult(int resultId) throws SQLException
    {
        new ResultDAO().approveResult(resultId);
    }
    public void editResult(Result item) throws SQLException
    {
        new ResultDAO().editResult(item);
    }
    public ArrayList getResultById(int id) throws SQLException {
        return new ResultDAO().getResultById(id);
    }
}
